/*
 * CS_SOCIAL_CONFIRM_NEWS.cpp
 *
 *  Created on: 2013. 6. 4.
 *      Author: the2
 */


#include "../../Command.h"
#include "../../User.h"
#include "../../Proxy.h"
#include "../../../../protocol/iFriends.h"
#include "../../NResource/Static.h"

namespace ProjectZ { namespace NCommand {

void Command::CS_SOCIAL_CONFIRM_NEWS(User * pUser, ::Network::Packet * pPacket)
{
	PREPARE_PACKET;
	ConfirmNewsSyn msg;

	pPacket->ParseMsg("%c", &msg.type);
	*pPacket >> msg.news_seq >> msg.gid;

	NResource::BalanceResource * balanceResource = NResource::Static::InstancePtr()->GetBalance();
	msg.heart_count_max = balanceResource->GetValue(pUser, EM_FRIEND_POINT_MAX);

	::ProjectZ::NProxy::SendFriendsServer(pUser->GetUserSeq(), msg);
}

} /*NCommand*/ } /*ProjectZ*/

